export const charging_counts_option = {
  title: {
    text: "今日充电次数曲线(次)",
    textStyle: {
      color: "#ffffff",
      fontSize: 16,
    },
  },
  tooltip: {
    trigger: "axis",
    axisPointer: {
      type: "cross",
      label: {
        backgroundColor: "#6a7985",
      },
    },
  },

  grid: {
    left: '3%',
    right: '4%',
    bottom: '3%',
    containLabel: true
  },

  legend: {
    data: ["今日", "昨日"],
    x: "right",
    textStyle: {
      color: "#ffffff",
    },
  },
  xAxis: {
    type: "category",
    boundaryGap: false,
    axisLabel: {
      interval: 1,
      color: "#ffffff",
    },
    axisLine: {
      lineStyle: {
        color: "#ffffff",
      },
    },
    data: [],  //data.hour_list,
  },
  yAxis: {
    type: "value",
    axisLabel: {
      interval: 1,
      color: "#ffffff",
    },
    axisLine: {
      lineStyle: {
        color: "#ffffff",
      },
    },
  },
  series: [
    {
      name: "昨日",
      type: "line",
      smooth: true,
      itemStyle: {
        color: "#1370fb",
      },
      data: [], //data.yesterday_count,
    },
    {
      name: "今日",
      type: "line",
      smooth: true,
      itemStyle: {
        color: "#ff5ca9",
      },
      data: [], //data.today_count,
    },
  ],
}

export const charging_readings_option = {
  title: {
    text: '今日充电量曲线(KWH)',
    textStyle: {
      color: '#ffffff',
      fontSize: 16,
    }
  },
  tooltip: {
    trigger: 'axis',
    axisPointer: {
      type: 'cross',
      label: {
        backgroundColor: '#6a7985'
      }
    }
  },
  grid: {
    left: '3%',
    right: '4%',
    bottom: '3%',
    containLabel: true
  },
  legend: {
    data: ['今日', '昨日'],
    x: 'right',
    textStyle: {
      color: '#ffffff',
    }
  },
  xAxis: {
    type: 'category',
    boundaryGap: false,
    axisLabel: {
      interval: 1,
      color: '#ffffff',
    },
    axisLine: {
      lineStyle: {
        color: '#ffffff',
      },
    },
    data: [], //data.hour_list,
  },
  yAxis: {
    type: 'value',
    axisLabel: {
      interval: 1,
      color: '#ffffff',
    },
    axisLine: {
      lineStyle: {
        color: '#ffffff',
      },
    },
  },
  series: [
    {
      name: '昨日',
      type: 'line',
      smooth: true,
      itemStyle: {
        color: '#1370fb',
      },
      data: [], //data.yesterday_readings,
    },
    {
      name: '今日',
      type: 'line',
      smooth: true,
      itemStyle: {
        color: "#00db95",
      },
      data: [], //data.today_readings,
    },
  ]
}


export const charging_money_option = {
  title: {
    text: '今日充电金额曲线(元)',
    textStyle: {
      color: '#ffffff',
      fontSize: 16,
    }
  },
  tooltip: {
    trigger: 'axis',
    axisPointer: {
      type: 'cross',
      label: {
        backgroundColor: '#6a7985'
      }
    }
  },
  grid: {
    left: '3%',
    right: '4%',
    bottom: '3%',
    containLabel: true
  },
  legend: {
    data: ['今日', '昨日'],
    x: 'right',
    textStyle: {
      color: '#ffffff',
    }
  },
  xAxis: {
    type: 'category',
    boundaryGap: false,
    axisLabel: {
      interval: 1,
      color: '#ffffff',
    },
    axisLine: {
      lineStyle: {
        color: '#ffffff',
      },
    },
    data: [], //data.hour_list,
  },
  yAxis: {
    type: 'value',
    axisLabel: {
      interval: 1,
      color: '#ffffff',
    },
    axisLine: {
      lineStyle: {
        color: '#ffffff',
      },
    },
  },
  series: [
    {
      name: '昨日',
      type: 'line',
      smooth: true,
      itemStyle: {
        color: '#1370fb',
      },
      data: [], //data.yesterday_money,
    },
    {
      name: '今日',
      type: 'line',
      smooth: true,
      itemStyle: {
        color: "#f5d94e",
      },
      data: [], //data.today_money,
    },
  ]
};

export const ratio_option = {

  title: {
    text: "",
    offset: [0, 120],
    style: {
      fill: "#fff",
    },
  },
  series: [
    {
      type: "gauge",
      data: [
        {
          name: "itemA",
          value: 0,
          gradient: ["#08f0ff", "#0184fb", "#0185ff"],
        },
      ],
      arcLineWidth: 20,
      center: ["50%", "45%"],
      radius: "20%",
      show: false,
      axisLabel: {
        formatter: "{value}%",
        style: {
          fill: "#fff",
        },
      },
      backgroundArc: {
        style: {
          stroke: '#081e4c',
          lineCap: "round",
        },
      },
      dataItemStyle: {
        lineCap: "round",
      },
      axisTick: {
        style: {
          stroke: "#fff",
        },
      },
      axisLabel: {
        show: false,
      },
      axisTick: {
        show: false,
      },
      pointer: {
        show: false,
      },
      details: {
        show: true,
        formatter: "{value}%",
        style: {
          fill: "#1ed3e5",
          fontSize: 25,
        },
      },
      animationCurve: "easeInOutBack",
    },
  ],
};